//package cn.base.web.gateway.config;
//
//import org.springframework.context.annotation.Configuration;
//import org.springframework.context.annotation.Bean;
//import org.springframework.context.annotation.Configuration;
//import org.springframework.web.server.ServerWebExchange;
//import org.springframework.web.server.session.CookieWebSessionIdResolver;
//import org.springframework.web.server.session.DefaultWebSessionManager;
//import org.springframework.web.server.session.WebSessionManager;
//gateway没有session，不用尝试关闭
//@Configuration
//public class SessionConfiguration {
//
//    @Bean
//    public WebSessionManager webSessionManager() {

//        DefaultWebSessionManager defaultWebSessionManager = new DefaultWebSessionManager();
//        defaultWebSessionManager.setSessionIdResolver(new CookieWebSessionIdResolver(){
//            @Override
//            public void expireSession(ServerWebExchange exchange) {
//                //session 过期不做任何处理
//            }
//        });
//
//        return defaultWebSessionManager;
//    }
//}
//
